using System;

namespace VirtualManagerSA
{
	/// <summary>
	/// This class holds all of the variables necessary for any given manager to hold
	/// at any time: both those stored in the database, and more temporary ones. Though
	/// it never directly interacts with the database, it is a convenient encapsulation of
	/// everything related to the manager.
	/// </summary>
	public class Manager
	{
		/*Global Variables*/
		string userid;
		string username;
		string password;

		//Basic (and unused) constructor
		public Manager()
		{
		}

		//Constructor that creates a new manager with all the instance variables.
		public Manager(string uid, string uname, string pass) 
		{
			userid = uid;
			username = uname;
			password = pass;
		}

		//Returns the MD5 hash of the manager's password.
		public string getPassword() 
		{
			return password;
		}

		//Sets the manager's password (the input is assumed to have already been MD5'ed. Yes, of course that's a verb.
		public void setPassword(string pass) 
		{
			password = pass;
		}

		//Returns the manager's username.
		public string getName() 
		{
			return username;
		}

		//Returns the manager's userid.
		public string getId() 
		{
			return userid;
		}
	}
}
